<HTML><HEAD><TITLE>meta(?Var)</TITLE>
</HEAD><BODY>[ <A HREF="index.html">Type Testing</A> | <A HREF="../../index.html">Reference Manual</A> | <A HREF="../../fullindex.html">Alphabetic Index</A> ]
<H1>meta(?Var)</H1>
Succeeds if Var is an attributed variable.


<DL>
<DT><EM>Var</EM></DT>
<DD>Prolog term.
</DD>
</DL>
<H2>Description</H2>
   Used to test whether Var is an attributed variable.
<P>
   CAUTION: this test only detects the presence of any attribute, which is
   usually not what is required. It is more common to check for the presence
   of a particular attribute by using a matching clause of the form:
<PRE>
    has_my_attribute(_{my_attr:Attr}) ?-
    	nonvar(Attr).
</PRE>

<H3>Modes and Determinism</H3><UL>
<LI>meta(?) is semidet
</UL>
<H3>Fail Conditions</H3>
Fails if Var is not an attributed variable
<H2>Examples</H2>
<PRE>
Success:
      meta(X{a}).
      suspend:(X&gt;0), meta(X).

Fail:
      meta(atom).
      meta(X).



</PRE>
<H2>See Also</H2>
<A HREF="../../kernel/typetest/free-1.html">free / 1</A>, <A HREF="../../kernel/typetest/type_of-2.html">type_of / 2</A>, <A HREF="../../kernel/typetest/var-1.html">var / 1</A>
</BODY></HTML>
